<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic" prefix="logic" %>
<div class="block small center login">
    <div class="block_head">
        <div class="bheadl"></div>
        <div class="bheadr"></div>
        <logic:empty name="successMessage">
            <h2>Forgot Password?</h2>
        </logic:empty>
        <logic:notEmpty name="successMessage">
            <h2>Email sent to your email address.</h2>
        </logic:notEmpty>
        <ul>
            <li><a href="<%=request.getContextPath()%>">back to the site</a></li>
        </ul>
    </div>
    <!-- .block_head ends -->
    
    <div class="block_content clearfix">
        <logic:empty name="successMessage">
            <logic:notEmpty name="errorMessage" >
                <div class="message errormsg"><p><bean:write name="errorMessage"/></p></div>
            </logic:notEmpty>
            <html:form styleClass="validate-form" action="admin/forgotPassword.do">
                <p>To reset your password, enter the username you use to sign in to NTB System.</p>
                <p>
                    <html:hidden property="action" value="forgot"/>
                    <label>Username:</label> <br/>
                    <html:text property="username" styleClass="text required"
                               title="Please enter your username"/>
                </p>
                <p>
                    <html:submit styleClass="submit long" value="Get new password"/>
                </p>
            </html:form>
        </logic:empty>
        <logic:notEmpty name="successMessage">
            <p>To get back into your account, follow the instructions we've sent to your email address.</p>
            <p><a class="submit long gray" href="<%=request.getContextPath()%>">back to the site</a></p>
        </logic:notEmpty>
    </div>
    <!-- .block_content ends -->
    
    <div class="bendl"></div>
    <div class="bendr"></div>
    
</div>
<!-- .login ends -->